home *** CD-ROM | disk | FTP | other *** search
/ CU Amiga Super CD-ROM 25 / CU Amiga Magazine's Super CD-ROM 25 (1998)(EMAP Images)(GB)(Track 1 of 2)[!][issue 1998-08].iso / CUCD / Utilities / SmartFilesystem / Include / bitmap.h < prev    next >
Encoding:
C/C++ Source or Header  |  1998-06-14  |  863 b   |  32 lines

  1. #include "blockstructure.h"
  2.  
  3. #define SPACELIST_MAX (1000)
  4.  
  5. /* Used by smartfindandmarkspace() */
  6.  
  7. struct Space {
  8.   BLCK block;
  9.   UWORD blocks;
  10. };
  11.  
  12.  
  13.  
  14. /* The fsBitmap structure is used for Bitmap blocks.  Every partition has
  15.    a bitmap, and the number of blocks the partition consists of determines
  16.    its size.  The position of the first Bitmap block is stored in the root
  17.    block.  If there are any more bitmap blocks then these are located in
  18.    order directly after the first bitmap block.  For every block on disk
  19.    there is a single bit in a bitmap block which tells you whether it is
  20.    in use or not. */
  21.  
  22. #define BITMAP_ID               MAKE_ID('B','T','M','P')
  23.  
  24. struct fsBitmap {
  25.   struct fsBlockHeader bheader;
  26.  
  27.   ULONG bitmap[0];
  28.  
  29.   /* Bits are 1 if the block is free, and 0 if full.
  30.      Bitmap must consist of an integral number of longwords. */
  31. };
  32.